﻿using System;

namespace _07_Console
{
    internal class Program
    {
        static void Main(string[] args)
        {
            //int[] arr;
            ////int[] arr = new int[10];
            ////arr[0] = 10;
            ////arr[1] = 20;

            //int[] arr1 = new int[5] { 1, 2, 3, 4, 5, };
            //double[] arr2 = new double[5] { 1.1, 2.2, 3.3, 4.4, 5.5 };
            //float[] arr3 = new float[] { 1.1f, 2.2f, 3.3f };
            //decimal[] arr4 = { 1.5156m, 151.1561561m, 123.15616156m, 2.45646m };
            //Console.WriteLine(arr4.Length);
            //int[] arr1 = new int[5];
            //for(int i = 0; i < 5; i++)
            //{
            //    string str = Console.ReadLine();
            //    arr1[i] = Convert.ToInt32(str);
            //}
            //for (int i = 0; i < arr1.Length; i++)
            //{
            //    Console.WriteLine(arr1[i]);
            //}
            //foreach (int i in arr1)
            //{
            //    Console.WriteLine(i);
            //}
            int[] arr = { 1, 2, 34, 846, 84, 1, 5, 4564, 1, 23, 18, 4, 84, 8, 7, 10 };
            //for(int i = 0; i < arr.Length-1; i++)
            //{
            //    for(int j = 0; j < arr.Length - i - 1; j++)
            //    {
            //        if(arr[j] > arr[j + 1])
            //        {
            //            arr[j] += arr[j + 1];
            //            arr[j+1] = arr[j] - arr[j+1];
            //            arr[j] = arr[j] - arr[j+1];
            //        }
            //    }
            //}
            Array.Sort(arr);
            foreach(int i in arr)
            {
                Console.Write($"{i},");
            }
        }
    }
}
